home *** CD-ROM | disk | FTP | other *** search
/ Aminet 38 / Aminet 38 (2000)(Schatztruhe)[!][Aug 2000].iso / Aminet / util / cli / Arename.readme < prev    next >
Encoding:
Text File  |  2000-07-01  |  4.8 KB  |  130 lines

  1. Short:    V1.0 Create rename/un scripts num-orderd +src
  2. Author:   mark@kontumnam.freeserve.co.uk (Mark Weller)
  3. Uploader: mark@kontumnam.freeserve.co.uk (Mark Weller)
  4. Type:     util/cli
  5. Url:      www.kontumnam.freeserve.co.uk
  6.  
  7. Arename
  8. --------
  9. This program produces a script file to rename chosen files in a chosen
  10.  directory  in a numberd format with a few other options.
  11.  
  12.  * The scripts use the amigados rename command
  13.  * you can rename all files in directory or by files by chosen extension.
  14.  
  15. I mainly wanted a small util to rename picture files in the format
  16.  pic0000.jpg,pic0001.jpg,.....pic0033.jpg and be able to rename them back
  17.  to the original name using amigados scripts. but I now use the program for
  18.  various other tasks, keeping image names for web pages simple and also
  19.  I have a pc running linux os and use ms-dos floppys to copy data files
  20.  between the two. ms-dos as the long filename problem,
  21.  It may be easier to archive the files - (lha keeps the long filenames), but
  22.  is not always a good option for other reasons.
  23.  
  24.  
  25.    I have included the source code with this program - I used Dice to
  26.      compile it, but should compile using any compiler - use it as you wish.
  27.  
  28.    If you find this program or source code useful please e-mail me
  29.     if not - sorry for wasting your time!
  30.  
  31. Usage
  32. -----
  33.   Arename <-ve> [directory] [name] [ext] <user ext>
  34.  
  35.  switches: -
  36.             v  = verbose - displays output to the screen
  37.  
  38.             e  = this option allows you to select files by thier
  39.                  extension - the default is all files in the directory
  40.                   (including .info files)
  41.  
  42.  
  43.     directory  = containing files to rename (ie: work:images)
  44.  
  45.          name  = new file name (ie: pics) this will be text before the
  46.                  numbers (ie: pics0000.img). use "" if you want just
  47.                   numbers (ie: 0000.img 0001.img 0002.img ....)
  48.  
  49.           ext  = extension for new filename (ie: img) would produce
  50.                  img on the end of the renamed files (ie: frame0000.img)
  51.  
  52.                  -*- Two important notes -*-
  53.  
  54.                   1) the script files created by this program (which will
  55.                      be created in the directory containing the files to
  56.                      be renamed) have the extension 'scp'. These files
  57.                      are ignored by the program.
  58.  
  59.                   2) This extension is used to make part of the script
  60.                      name, there are to scripts one to rename and one to
  61.                      undo. example if you choose img as the extension :-
  62.  
  63.                        rename script : Arenimg.scp
  64.                        undo script   : Aundimg.scp
  65.  
  66.  
  67.      user ext  = Will only rename files with this extension (use with -e)
  68.                   (ie: jpg  - only jpeg files in the directory)
  69.  
  70.                 example -:
  71.                  if you have a directory with different image types
  72.                  .iff .gif .ilbm .jpg and they all had .info files
  73.                  but you do not want to include the .info files in your
  74.                  renaming.
  75.  
  76.                  :> Arename -ve work:mydirectory temp scp info
  77.                  :> execute Arenscp.scp
  78.  
  79.                  this will change all .info files to have .scp
  80.                   as the extension.
  81.                    butterfly.jpg.info ->   temp0000.scp
  82.                    cowboy.gif.info    ->   temp0001.scp
  83.  
  84.                  :> Arename -v work:mydirectory frame img
  85.                  :> execute Arenimg.scp
  86.  
  87.                  this will rename all the files in the directory
  88.                   ignoring the .scp files (which where mainly .info
  89.                   files) to.
  90.                     butterfly.jpg    ->    frame0000.img
  91.                     cowboy.gif       ->    frame0001.img
  92.                   -*- now do what you want with the image files -*-
  93.  
  94.                  :> execute Aundscp.scp
  95.                  :> execute Aundimg.scp
  96.  
  97.                   this will restore all files back to their original names
  98.                   if you want to.
  99.  
  100. Examples
  101. --------
  102.  example: Arename -v Work:pics holiday jpg
  103.   this will rename all files in the chosen  directory to:
  104.  
  105.   holiday0000.jpg,holiday0001.jpg,...holiday0023.jpg
  106.  
  107.  example: Arename -v Work:pics "" img
  108.   this will rename all files in the chosen  directory to:
  109.  
  110.   0000.img,0001.img,0002.img,0003.img,...0023.img
  111.  
  112.  example: Arename -v Work:pics caves img jpg
  113.   this will rename all files in the chosendirectory with the
  114.    extension jpg to:
  115.  
  116.   caves0000.img,...caves0023.img
  117.  
  118.     -*- Mark Weller -*-
  119.  
  120.  
  121. ============================= Archive contents =============================
  122.  
  123. Original  Packed Ratio    Date     Time    Name
  124. -------- ------- ----- --------- --------  -------------
  125.    12128    7035 41.9% 14-Jun-00 14:23:44 +Arename
  126.     9517    2382 74.9% 14-Jun-00 14:23:32 +Arename.c
  127.     4530    1629 64.0% 14-Jun-00 19:24:02 +Arename.readme
  128. -------- ------- ----- --------- --------
  129.    26175   11046 57.7% 15-Jun-100 06:56:40   3 files
  130.